Update dependency rules_python to v2#50507
Conversation
|
PRApprover will approve and merge this PR, FAQ, #dx-source-code-management 🛠️ PRApproval Status
➡️ Current phase: CI tests failed. Please fix the failing tests to continue. |
This commit was created from the local commit with hash 5b71612dd53517baaa9af81943556fbf65e0555c.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a4b5fcb470
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Files inventory check summaryFile checks results against ancestor b4b1b538: Results for datadog-agent_7.80.0~devel.git.588.2ac6727.pipeline.112070113-1_amd64.deb:No change detected |
Static quality checks✅ Please find below the results from static quality gates 33 successful checks with minimal change (< 2 KiB)
|
Regression DetectorRegression Detector ResultsMetrics dashboard Baseline: b73d762 Optimization Goals: ✅ No significant changes detected
|
| perf | experiment | goal | Δ mean % | Δ mean % CI | trials | links |
|---|---|---|---|---|---|---|
| ➖ | docker_containers_cpu | % cpu utilization | +0.87 | [-2.08, +3.82] | 1 | Logs |
Fine details of change detection per experiment
| perf | experiment | goal | Δ mean % | Δ mean % CI | trials | links |
|---|---|---|---|---|---|---|
| ➖ | quality_gate_logs | % cpu utilization | +0.89 | [-0.08, +1.87] | 1 | Logs bounds checks dashboard |
| ➖ | docker_containers_cpu | % cpu utilization | +0.87 | [-2.08, +3.82] | 1 | Logs |
| ➖ | file_tree | memory utilization | +0.51 | [+0.46, +0.57] | 1 | Logs |
| ➖ | ddot_metrics_sum_cumulativetodelta_exporter | memory utilization | +0.31 | [+0.07, +0.54] | 1 | Logs |
| ➖ | ddot_logs | memory utilization | +0.24 | [+0.18, +0.31] | 1 | Logs |
| ➖ | otlp_ingest_logs | memory utilization | +0.02 | [-0.08, +0.12] | 1 | Logs |
| ➖ | uds_dogstatsd_to_api | ingress throughput | +0.02 | [-0.20, +0.23] | 1 | Logs |
| ➖ | ddot_metrics_sum_cumulative | memory utilization | +0.01 | [-0.14, +0.17] | 1 | Logs |
| ➖ | file_to_blackhole_0ms_latency | egress throughput | +0.01 | [-0.51, +0.54] | 1 | Logs |
| ➖ | file_to_blackhole_1000ms_latency | egress throughput | +0.01 | [-0.42, +0.43] | 1 | Logs |
| ➖ | file_to_blackhole_100ms_latency | egress throughput | +0.00 | [-0.14, +0.15] | 1 | Logs |
| ➖ | uds_dogstatsd_to_api_v3 | ingress throughput | +0.00 | [-0.21, +0.21] | 1 | Logs |
| ➖ | tcp_dd_logs_filter_exclude | ingress throughput | -0.03 | [-0.14, +0.08] | 1 | Logs |
| ➖ | file_to_blackhole_500ms_latency | egress throughput | -0.06 | [-0.46, +0.34] | 1 | Logs |
| ➖ | ddot_metrics | memory utilization | -0.10 | [-0.30, +0.09] | 1 | Logs |
| ➖ | otlp_ingest_metrics | memory utilization | -0.12 | [-0.28, +0.05] | 1 | Logs |
| ➖ | ddot_metrics_sum_delta | memory utilization | -0.22 | [-0.40, -0.04] | 1 | Logs |
| ➖ | tcp_syslog_to_blackhole | ingress throughput | -0.25 | [-0.45, -0.06] | 1 | Logs |
| ➖ | quality_gate_idle | memory utilization | -0.26 | [-0.30, -0.21] | 1 | Logs bounds checks dashboard |
| ➖ | uds_dogstatsd_20mb_12k_contexts_20_senders | memory utilization | -0.31 | [-0.36, -0.26] | 1 | Logs |
| ➖ | quality_gate_idle_all_features | memory utilization | -0.40 | [-0.45, -0.36] | 1 | Logs bounds checks dashboard |
| ➖ | docker_containers_memory | memory utilization | -0.52 | [-0.62, -0.42] | 1 | Logs |
| ➖ | quality_gate_metrics_logs | memory utilization | -0.90 | [-1.15, -0.66] | 1 | Logs bounds checks dashboard |
Bounds Checks: ✅ Passed
| perf | experiment | bounds_check_name | replicates_passed | observed_value | links |
|---|---|---|---|---|---|
| ✅ | docker_containers_cpu | simple_check_run | 10/10 | 689 ≥ 26 | |
| ✅ | docker_containers_memory | memory_usage | 10/10 | 245.78MiB ≤ 370MiB | |
| ✅ | docker_containers_memory | simple_check_run | 10/10 | 680 ≥ 26 | |
| ✅ | file_to_blackhole_0ms_latency | memory_usage | 10/10 | 0.16GiB ≤ 1.20GiB | |
| ✅ | file_to_blackhole_0ms_latency | missed_bytes | 10/10 | 0B = 0B | |
| ✅ | file_to_blackhole_1000ms_latency | memory_usage | 10/10 | 0.21GiB ≤ 1.20GiB | |
| ✅ | file_to_blackhole_1000ms_latency | missed_bytes | 10/10 | 0B = 0B | |
| ✅ | file_to_blackhole_100ms_latency | memory_usage | 10/10 | 0.17GiB ≤ 1.20GiB | |
| ✅ | file_to_blackhole_100ms_latency | missed_bytes | 10/10 | 0B = 0B | |
| ✅ | file_to_blackhole_500ms_latency | memory_usage | 10/10 | 0.18GiB ≤ 1.20GiB | |
| ✅ | file_to_blackhole_500ms_latency | missed_bytes | 10/10 | 0B = 0B | |
| ✅ | quality_gate_idle | intake_connections | 10/10 | 3 ≤ 4 | bounds checks dashboard |
| ✅ | quality_gate_idle | memory_usage | 10/10 | 141.18MiB ≤ 147MiB | bounds checks dashboard |
| ✅ | quality_gate_idle_all_features | intake_connections | 10/10 | 3 ≤ 4 | bounds checks dashboard |
| ✅ | quality_gate_idle_all_features | memory_usage | 10/10 | 468.73MiB ≤ 495MiB | bounds checks dashboard |
| ✅ | quality_gate_logs | intake_connections | 10/10 | 4 ≤ 6 | bounds checks dashboard |
| ✅ | quality_gate_logs | memory_usage | 10/10 | 176.65MiB ≤ 195MiB | bounds checks dashboard |
| ✅ | quality_gate_logs | missed_bytes | 10/10 | 0B = 0B | bounds checks dashboard |
| ✅ | quality_gate_metrics_logs | cpu_usage | 10/10 | 361.78 ≤ 2000 | bounds checks dashboard |
| ✅ | quality_gate_metrics_logs | intake_connections | 10/10 | 3 ≤ 6 | bounds checks dashboard |
| ✅ | quality_gate_metrics_logs | memory_usage | 10/10 | 371.66MiB ≤ 430MiB | bounds checks dashboard |
| ✅ | quality_gate_metrics_logs | missed_bytes | 10/10 | 0B = 0B | bounds checks dashboard |
Explanation
Confidence level: 90.00%
Effect size tolerance: |Δ mean %| ≥ 5.00%
Performance changes are noted in the perf column of each table:
- ✅ = significantly better comparison variant performance
- ❌ = significantly worse comparison variant performance
- ➖ = no significant change in performance
A regression test is an A/B test of target performance in a repeatable rig, where "performance" is measured as "comparison variant minus baseline variant" for an optimization goal (e.g., ingress throughput). Due to intrinsic variability in measuring that goal, we can only estimate its mean value for each experiment; we report uncertainty in that value as a 90.00% confidence interval denoted "Δ mean % CI".
For each experiment, we decide whether a change in performance is a "regression" -- a change worth investigating further -- if all of the following criteria are true:
-
Its estimated |Δ mean %| ≥ 5.00%, indicating the change is big enough to merit a closer look.
-
Its 90.00% confidence interval "Δ mean % CI" does not contain zero, indicating that if our statistical model is accurate, there is at least a 90.00% chance there is a difference in performance between baseline and comparison variants.
-
Its configuration does not mark it "erratic".
CI Pass/Fail Decision
✅ Passed. All Quality Gates passed.
- quality_gate_idle_all_features, bounds check memory_usage: 10/10 replicas passed. Gate passed.
- quality_gate_idle_all_features, bounds check intake_connections: 10/10 replicas passed. Gate passed.
- quality_gate_metrics_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
- quality_gate_metrics_logs, bounds check cpu_usage: 10/10 replicas passed. Gate passed.
- quality_gate_metrics_logs, bounds check missed_bytes: 10/10 replicas passed. Gate passed.
- quality_gate_metrics_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
- quality_gate_idle, bounds check intake_connections: 10/10 replicas passed. Gate passed.
- quality_gate_idle, bounds check memory_usage: 10/10 replicas passed. Gate passed.
- quality_gate_logs, bounds check memory_usage: 10/10 replicas passed. Gate passed.
- quality_gate_logs, bounds check intake_connections: 10/10 replicas passed. Gate passed.
- quality_gate_logs, bounds check missed_bytes: 10/10 replicas passed. Gate passed.
|
/merge |
|
View all feedbacks in Devflow UI.
PR already in the queue with status waiting |
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [rules_python](https://redirect.github.com/bazel-contrib/rules_python) | bazel_dep | major | `1.9.0` → `2.0.0` | --- ### Release Notes <details> <summary>bazel-contrib/rules_python (rules_python)</summary> ### [`v2.0.0`](https://redirect.github.com/bazel-contrib/rules_python/blob/HEAD/CHANGELOG.md#200---2026-04-09) [Compare Source](https://redirect.github.com/bazel-contrib/rules_python/compare/1.9.0...2.0.0) [2.0.0]: https://redirect.github.com/bazel-contrib/rules_python/releases/tag/2.0.0 {#v2-0-0-removed} ##### Removed - Nothing removed. {#v2-0-0-changed} ##### Changed **Breaking** - {obj}`--windows_enable_symlinks` is required. Add `startup --windows_enable_symlinks` to your `.bazelrc` to enable Bazel using full symlink support on Windows. - venv-based binaries are created by default ({obj}`--bootstrap_impl=system_python`) on supported platforms (Linux/Mac with Bazel 8+, or Windows). - `--build_python_zip` on Windows is ignored. Use {obj}`py_zipapp_binary` to create zips of Python programs. - (pypi) Previously `experimental_index_url` users would not need to specify target platforms if cross-building is required. From now we will only pull wheels for the host OS to better align with how the rules work with the legacy `pip` implementation. Use {obj}`pip.parse.target_platforms` to customize the behavior. Related to [#​260](https://redirect.github.com/bazel-contrib/rules_python/issues/260). Other changes: - (pypi) Update dependencies used for `compile_pip_requirements`, building sdists in the `whl_library` rule and fetching wheels using `pip`. - (pypi) Before using the bazel downloader to fetch the PyPI package metadata we will from now on fetch the lists of available packages on each index. The used package mappings will be written as facts to the `MODULE.bazel.lock` file on supported bazel versions and it should be done at most once. As a result, per-package {obj}`experimental_index_url_overrides` is no longer needed, but if specified, it needs to be provided for all packages not on the default index. What is more, the flags for `--index_url` and `--extra-index-url` now behave in the same way as in `uv` or `pip`, i.e. we default to `--index-url` if the package is not found in `--extra-index-url`. Fixes ([#​3260](https://redirect.github.com/bazel-contrib/rules_python/issues/3260) and [#​2632](https://redirect.github.com/bazel-contrib/rules_python/issues/2632)). - (uv) We will now use the download URL specified in the `uv`'s `dist_manifest.json` file. If you have redirects or blocking rules as part of your downloader setup, you may need to adjust them. What is more, the default uv version has been bumped `0.11.2`. - (runfiles): Type annotations are no longer tested for Python 3.9. - Windows no longer defaults to creating a zip file and extracting it; a symlink-based runfiles tree is created, as on unix-like platforms. {#v2-0-0-fixed} ##### Fixed - (toolchain) Also set Make variables for local toolchains. - (zipapp) Resolve issue passing through compression settings in `py_zippapp_binary` targets ([#​3646](https://redirect.github.com/bazel-contrib/rules_python/issues/3646)). - (toolchains) The pyc created at runtime in the stdlib should no longer cause the Python runtime repository to be invalidated. The stdlib pyc files *may* be reused in between invocations, depending upon the sandboxing configuration. See the {any}`RULES_PYTHON_PYCACHE_DIR` environment variable for more information. ([#​3643](https://redirect.github.com/bazel-contrib/rules_python/issues/3643)). - (bootstrap) Fixed incorrect runfiles path construction in bootstrap scripts when binary is defined in another bazel module ([#​3563](https://redirect.github.com/bazel-contrib/rules_python/issues/3563)). - (bootstrap) Resolve `RUNFILES_DIR` inheritance issues, which lead to a child Python binary incorrectly using it's parent's Python binary environment ([#​3518](https://redirect.github.com/bazel-contrib/rules_python/issues/3518)). - (uv) Downloads for versions `>=0.10` work again. In order to fix this we had drop support for `powerpc64` platform. People interested in the platform can bring it back via the `uv.default` API. Like: ``` uv.default( compatible_with = [ "@​platforms//os:linux", "@​platforms//cpu:ppc", ], platform = "powerpc64-unknown-linux-gnu", ) ``` Fixes [#​3676](https://redirect.github.com/bazel-contrib/rules_python/issues/3676). - (pypi) Fixes wheel extraction on hosts without python installed, Fixes [#​3712](https://redirect.github.com/bazel-contrib/rules_python/issues/3712). {#v2-0-0-added} ##### Added - (pypi) Write SimpleAPI contents to the `MODULE.bazel.lock` file if using {obj}`experimental_index_url` which should speed up consecutive initializations and should no longer require the network access if the cache is hydrated. Implements [#​2731](https://redirect.github.com/bazel-contrib/rules_python/issues/2731). - (pypi) The `--index-url` and `--extra-index-url` is now parsed from the lock file and the {obj}`pip.parse.experimental_index_url` and {obj}`pip.parse.experimental_extra_index_urls` is no longer mandatory to leverage the bazel downloader. Implements [#​1357](https://redirect.github.com/bazel-contrib/rules_python/issues/1357), [#​2951](https://redirect.github.com/bazel-contrib/rules_python/issues/2951). - (pypi) If cross-compilation is needed, use the {obj}`pip.parse.target_platforms` to specify exactly which platforms should be supported. Implements [#​260](https://redirect.github.com/bazel-contrib/rules_python/issues/260). - (wheel) Specifying a path ending in `/` as a destination in `data_files` will now install file(s) to a folder, preserving their basename. - Various attributes and fields added to support venvs on Windows: - {obj}`py_runtime.venv_bin_files` and {obj}`PyRuntime.venv_binfiles` field added to specify additional Python runtime files Windows needs for venvs. - {obj}`PyExecutableInfo.venv_interpreter_runfiles`, and {obj}`PyExecutableInfo.venv_interpreter_symlinks` adde - (wheel) Add support for `add_path_prefix` argument in `py_wheel` which can be used to prepend a prefix to the files in the wheel. {#v1-9-0} </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - At 12:00 AM through 04:59 AM and 10:00 PM through 11:59 PM, Monday through Friday (`* 0-4,22-23 * * 1-5`) - Only on Sunday and Saturday (`* * * * 0,6`) - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/DataDog/datadog-agent). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4xNTkuMiIsInVwZGF0ZWRJblZlciI6IjQzLjE1OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJjaGFuZ2Vsb2cvbm8tY2hhbmdlbG9nIiwiZGVwZW5kZW5jaWVzIiwiZGVwZW5kZW5jaWVzLWJhemVsIiwicWEvbm8tY29kZS1jaGFuZ2UiXX0=--> Co-authored-by: dd-octo-sts[bot] <200755185+dd-octo-sts[bot]@users.noreply.github.com> Co-authored-by: regis.desgroppes <regis.desgroppes@datadoghq.com>
This PR contains the following updates:
1.9.0→2.0.0Release Notes
bazel-contrib/rules_python (rules_python)
v2.0.0Compare Source
{#v2-0-0-removed}
Removed
{#v2-0-0-changed}
Changed
Breaking
--windows_enable_symlinksis required. Addstartup --windows_enable_symlinksto your.bazelrcto enable Bazel using fullsymlink support on Windows.
--bootstrap_impl=system_python)on supported platforms (Linux/Mac with Bazel 8+, or Windows).
--build_python_zipon Windows is ignored. Use {obj}py_zipapp_binaryto createzips of Python programs.
experimental_index_urlusers would not need to specifytarget platforms if cross-building is required. From now we will only pull
wheels for the host OS to better align with how the rules work with the legacy
pipimplementation. Use {obj}pip.parse.target_platformsto customize thebehavior.
Related to #260.
Other changes:
compile_pip_requirements, buildingsdists in the
whl_libraryrule and fetching wheels usingpip.we will from now on fetch the lists of available packages on each index. The
used package mappings will be written as facts to the
MODULE.bazel.lockfileon supported bazel versions and it should be done at most once. As a result,
per-package {obj}
experimental_index_url_overridesis no longer needed, butif specified, it needs to be provided for all packages not on the default index. What
is more, the flags for
--index_urland--extra-index-urlnow behave in thesame way as in
uvorpip, i.e. we default to--index-urlif the packageis not found in
--extra-index-url. Fixes(#3260 and
#2632).
uv'sdist_manifest.jsonfile. If you have redirects or blocking rules as part ofyour downloader setup, you may need to adjust them. What is more, the default
uv version has been bumped
0.11.2.symlink-based runfiles tree is created, as on unix-like platforms.
{#v2-0-0-fixed}
Fixed
py_zippapp_binarytargets(#3646).
cause the Python runtime repository to be invalidated. The stdlib pyc files
may be reused in between invocations, depending upon the sandboxing
configuration. See the {any}
RULES_PYTHON_PYCACHE_DIRenvironment variablefor more information.
(#3643).
scripts when binary is defined in another bazel module
(#3563).
RUNFILES_DIRinheritance issues, which lead to a childPython binary incorrectly using it's parent's Python binary environment
(#3518).
>=0.10work again. In order to fix this we haddrop support for
powerpc64platform. People interested in the platform canbring it back via the
uv.defaultAPI. Like:Fixes #3712.
{#v2-0-0-added}
Added
MODULE.bazel.lockfile if using{obj}
experimental_index_urlwhich should speed up consecutiveinitializations and should no longer require the network access if the cache is
hydrated. Implements
#2731.
--index-urland--extra-index-urlis now parsed from the lockfile and the {obj}
pip.parse.experimental_index_urland{obj}
pip.parse.experimental_extra_index_urlsisno longer mandatory to leverage the bazel downloader.
Implements
#1357,
#2951.
pip.parse.target_platformsto specify exactly which platforms should be supported.
Implements
#260.
/as a destination indata_fileswill now install file(s) to a folder, preserving their basename.
py_runtime.venv_bin_filesand {obj}PyRuntime.venv_binfilesfield added to specify additional Python runtime files Windows needs for
venvs.
PyExecutableInfo.venv_interpreter_runfiles, and{obj}
PyExecutableInfo.venv_interpreter_symlinksaddeadd_path_prefixargument inpy_wheelwhich can beused to prepend a prefix to the files in the wheel.
{#v1-9-0}
Configuration
📅 Schedule: (UTC)
* 0-4,22-23 * * 1-5)* * * * 0,6)🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.